<extend name="_Layout/main"/>
<block name="style">

</block>
<block name="main">
    <div class="builder-container builder-form-container">
        <div class="row">
            <div class="col-xs-12">
                <div class="table-responsive">
                    <h3>{$listname}</h3>
                    <a style="margin-bottom: 10px;"   href="{:U('Admin/Jihuoma/index')}&select=1" class="btn btn-success">全部</a>
                    <a style="margin-bottom: 10px;"   href="{:U('Admin/Jihuoma/index')}&select=2" class="btn btn-default">已使用</a>
                    <a style="margin-bottom: 10px;"   href="{:U('Admin/Jihuoma/index')}&select=3" class="btn btn-default">未使用</a>
                    <a style="margin-bottom: 10px;"   href="{:U('Admin/Jihuoma/index')}&select=4" class="btn btn-default">已转过</a>
                    <div class="col-xs-12 col-sm-3" style="float:right;">
                        <div class="input-group search-form">
                            <form class="input-group search-form" method="post" action="{:U('Admin/Jihuoma/piliang')}">
                                <input type="text" name="piliang" class="search-input form-control" value="" placeholder="请输入批量导出数量">
                                <span class="input-group-btn"><button type="submit" class="btn btn-default"><i class="fa fa-key"></i></button></span>
                            </form>
                        </div>
                    </div>
                    <table class="table table-condensed">
                        <thead>
                        <tr class="success">
                            <th>序号</th>
                            <th>激活码</th>
                            <th>激活状态</th>
                            <th>生成时间</th>
                            <th>现任用户</th>
                            <th>前任用户</th>
                            <th>操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        <volist name="data_list" id="sf">
                            <tr>
                                <th scope="row">{$i}</th>
                                <td>{$sf.jihuoma}</td>
                                <td><if condition="$sf.jihuo_zhuangtai eq 0">未使用<else />已使用</if></td>
                                <td>{$sf.creattime}</td>
                                <th>{$sf.yy_username}</th>
                                <th>{$sf.ord_username}</th>
                                <td><a href="#" data-toggle="modal" data-target=".lbw_ddbzshensumingxi{$i}" class="btn btn-danger">查看</a></td>
                            </tr>
                            <div class="modal fade bs-example-modal-lg lbw_ddbzshensumingxi{$i}" tabindex="-1"  role="dialog" aria-labelledby="myLargeModalLabel">
                                <div class="modal-dialog modal-lg">
                                    <div class="modal-content" style="border-radius:10px;">
                                        <div class="modal-header" style="background: #44CDAF;color: #FFF;border-bottom: 1px solid #FFF;border-top-left-radius: 10px;border-top-right-radius: 10px;">
                                            <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                                            <h3 class="modal-title">使用激活码用户</h3>
                                        </div>
                                        <div class="modal-body">
                                            <div class="container-fluid">
                                                    <ul class="list-group">
                                                        <li class="list-group-item"><b>用户名: </b>{$sf.username}</li>
                                                    </ul>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                        </volist>
                        <tr>
                            <td style="color:#c9302c;">已使用: {$moneytotal}个</td>
                            <td style="color:#c9302c;">未使用: {$moneyypp}个</td>
                            <td style="color:#c9302c;">总数量: {$total}个</td>
                        </tr>
                        </tbody>
                    </table>
                    <ul class="pagination">{$page}</ul>
                </div>
            </div>
        </div>
    </div>
</block>